<?xml version="1.0" encoding="UTF-8"?>
<schema
	xmlns:gml="http://www.opengis.net/gml/3.2"
	xmlns:gmd="http://www.isotc211.org/2005/gmd"
	xmlns:om="http://www.opengis.net/om/2.0"
	xmlns="http://www.w3.org/2001/XMLSchema"
	xmlns:sam="http://www.opengis.net/sampling/2.0"
	xmlns:sams="http://www.opengis.net/samplingSpatial/2.0"
	targetNamespace="http://www.opengis.net/samplingSpatial/2.0"
	elementFormDefault="qualified"
	attributeFormDefault="unqualified"
	version="2.0.0">
	<annotation>
		<documentation> spatialSamplingFeature.xsd 
			
			Observations and Measurements - XML Implementation is an OGC Standard.
			
			Copyright (c) [2010] Open Geospatial Consortium, Inc. All Rights Reserved. 
			To obtain additional rights of use, visit http://www.opengeospatial.org/legal/.
		</documentation>
	</annotation>
	<!-- ====================================================================== -->
	<!-- bring in other schemas -->
	<import
		namespace="http://www.opengis.net/gml/3.2"
		schemaLocation="../../gml/3.2.1/gml.xsd"/>
	<import
		namespace="http://www.isotc211.org/2005/gmd"
		schemaLocation="../../iso/19139/20070417/gmd/gmd.xsd"/>
	<import
		namespace="http://www.opengis.net/sampling/2.0"
		schemaLocation="../../sampling/2.0/samplingFeature.xsd"/>
	<import
		namespace="http://www.opengis.net/om/2.0"
		schemaLocation="../../om/2.0.0/observation.xsd"/>
	<!-- ====================================================================== -->
	<!-- ====================================================================== -->
	<!-- Common properties of spatial sampling features -->
	<!-- ====================================================================== -->
	<group
		name="SF_SpatialCommonProperties">
		<annotation>
			<documentation> When observations are made to estimate properties of a geospatial
				feature, in particular where the value of a property varies within the scope of the
				feature, a spatial sampling feature is used. Depending on accessibility and on the
				nature of the expected property variation, the sampling feature may be extensive in
				one, two or three spatial dimensions. Processing and visualization methods are often
				dependent on the topological dimension of the sampling manifold, so this provides a
				natural classification system for sampling features. This classification follows
				common practice in focussing on conventional spatial dimensions. Properties observed
				on sampling features may be time-dependent, but the temporal axis does not generally
				contribute to the classification of sampling feature classes. Sampling feature
				identity is usually less time-dependent than is the property value. </documentation>
		</annotation>
		<sequence>
			<element
				name="hostedProcedure"
				type="om:OM_ProcessPropertyType"
				minOccurs="0"
				maxOccurs="unbounded">
				<annotation>
					<documentation> A common role for a spatial sampling feature is to host
						instruments or procedures deployed repetitively or permanently. If present,
						the association Platform shall link the SF_SpatialSamplingFeature to an
						OM_Process deployed at it. The OM_Process has the role hostedProcedure with
						respect to the sampling feature. </documentation>
				</annotation>
			</element>
			<element
				name="positionalAccuracy"
				type="gmd:DQ_PositionalAccuracy_PropertyType"
				minOccurs="0"
				maxOccurs="2">
				<annotation>
					<documentation> Positioning metadata is commonly associated with sampling
						features defined in the context of field surveys. If present,
						positionalAccuracy:DQ_PositionalAccuracy shall describe the accuracy of the
						positioning of the sampling feature. Up to two instances of the attribute
						support the independent description of horizontal and vertical accuracy.
					</documentation>
				</annotation>
			</element>
		</sequence>
	</group>
	<!-- ====================================================================== -->
	<!-- ====================================================================== -->
	<!-- Generic shape -->
	<!-- ====================================================================== -->
	<complexType
		name="shapeType">
		<sequence
			minOccurs="0">
			<element
				ref="gml:AbstractGeometry"/>
		</sequence>
		<attributeGroup
			ref="gml:AssociationAttributeGroup"/>
	</complexType>
	<element
		name="shape"
		type="sams:shapeType"/> 
	<!-- ====================================================================== -->
	<!-- ====================================================================== -->
	<!-- Spatial sampling feature -->
	<!-- ====================================================================== -->
	<complexType
		name="SF_SpatialSamplingFeatureType">
		<annotation>
			<documentation> When observations are made to estimate properties of a geospatial
				feature, in particular where the value of a property varies within the scope of the
				feature, a spatial sampling feature is used. Depending on accessibility and on the
				nature of the expected property variation, the sampling feature may be extensive in
				one, two or three spatial dimensions. Processing and visualization methods are often
				dependent on the topological dimension of the sampling manifold, so this provides a
				natural classification system for sampling features. This classification follows
				common practice in focussing on conventional spatial dimensions. Properties observed
				on sampling features may be time-dependent, but the temporal axis does not generally
				contribute to the classification of sampling feature classes. Sampling feature
				identity is usually less time-dependent than is the property value. </documentation>
		</annotation>
		<complexContent>
			<extension
				base="sam:SF_SamplingFeatureType">
				<sequence>
					<group
						ref="sams:SF_SpatialCommonProperties"/>
					<element
						ref="sams:shape">
						<annotation>
							<documentation> The association Geometry shall link a
								SF_SpatialSamplingFeature to a GM_Object that describes its shape.
							</documentation>
						</annotation>
					</element>
				</sequence>
			</extension>
		</complexContent>
	</complexType>
	<!-- .................. -->
	<element
		name="SF_SpatialSamplingFeature"
		type="sams:SF_SpatialSamplingFeatureType"
		substitutionGroup="sam:SF_SamplingFeature"/>
	<!-- .................. -->
	<complexType
		name="SF_SpatialSamplingFeaturePropertyType">
		<sequence
			minOccurs="0">
			<element
				ref="sams:SF_SpatialSamplingFeature"/>
		</sequence>
		<attributeGroup
			ref="gml:AssociationAttributeGroup"/>
	</complexType>
	<!-- ====================================================================== -->
	<!-- ====================================================================== -->
</schema>
